/*
//
//              INTEL CORPORATION PROPRIETARY INFORMATION
//  This software is supplied under the terms of a license  agreement or
//  nondisclosure agreement with Intel Corporation and may not be copied
//  or disclosed except in  accordance  with the terms of that agreement.
//    Copyright (c) 2007 Intel Corporation. All Rights Reserved.
//
//
*/

#ifndef __UMC_AVS_CONSTS_H
#define __UMC_AVS_CONSTS_H

#include "ippdefs.h"

namespace UMC
{

// all available start codes
enum
{
    LAST_SLICE_START_CODE       = 0x0af,
    VIDEO_SEQUENCE_START_CODE   = 0x0b0,
    VIDEO_SEQUENCE_END_CODE     = 0x0b1,
    USER_DATA_START_CODE        = 0x0b2,
    I_PICTURE_START_CODE        = 0x0b3,
    EXTENSION_START_CODE        = 0x0b5,
    BP_PICTURE_START_CODE       = 0x0b6,
    VIDEO_EDIT_CODE             = 0x0b7,
    FIRST_SYSTEM_START_CODE     = 0x0b9
};

#define AVS_CBP_UNKNOWN 0x07fffffff

// declare types of a macroblock
enum eAVSMbType
{
    I_8x8,

    P_Skip,
    P_16x16,
    P_16x8,
    P_8x16,
    P_8x8,

    B_Skip,
    B_Direct_16x16,
    B_Fwd_16x16,
    B_Bck_16x16,
    B_Sym_16x16,
    B_Fwd_Fwd_16x8,
    B_Fwd_Fwd_8x16,
    B_Bck_Bck_16x8,
    B_Bck_Bck_8x16,
    B_Fwd_Bck_16x8,
    B_Fwd_Bck_8x16,
    B_Bck_Fwd_16x8,
    B_Bck_Fwd_8x16,
    B_Fwd_Sym_16x8,
    B_Fwd_Sym_8x16,
    B_Bck_Sym_16x8,
    B_Bck_Sym_8x16,
    B_Sym_Fwd_16x8,
    B_Sym_Fwd_8x16,
    B_Sym_Bck_16x8,
    B_Sym_Bck_8x16,
    B_Sym_Sym_16x8,
    B_Sym_Sym_8x16,
    B_8x8
};

// declare block devision types
enum eAVSDivBlockType
{
    Div_16x16                   = 0,
    Div_16x8                    = 1,
    Div_8x16                    = 2,
    Div_8x8                     = 3
};

// declare block prediction types
enum eAVSPredType
{
    PredIntra                   = 0,
    PredForward                 = 1,
    PredBackward                = 2,
    PredBiDir                   = 3,

    // these two types are used only in decoding process.
    // in reconstruction process only four types above are availeble.
    PredDirect                  = 0,
    PredSym                     = 4 | PredForward
};

// declare chrominance resolution types
enum
{
    AVS_CHROMA_420_FORMAT       = 1,
    AVS_CHROMA_422_FORMAT       = 2
};

// declare block coding types
enum
{
    AVS_INTRA                   = 0,
    AVS_INTER                   = 1,

    AVS_CODING_TYPES
};

// declare block prediction directions types
enum
{
    AVS_FORWARD                 = 0,
    AVS_BACKWARD                = 1,

    AVS_DIRECTIONS
};

// declare picture structure types
enum eAVSPicStructure
{
    AVS_FRAME                   = 0,
    AVS_UPPER_FIELD             = 1,
    AVS_LOWER_FIELD             = 2,
    AVS_FIELD_PAIR              = 3
};

} // namespace UMC

#endif // __UMC_AVS_CONSTS_H
